package com.battery.system.domain;

import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.battery.common.annotation.Excel;
import com.battery.common.core.domain.BaseEntity;
import tk.mybatis.mapper.annotation.KeySql;

import javax.persistence.Id;
import javax.persistence.Table;

/**
 * 设备基础信息对象 ws_device_basics
 *
 * @author battery
 * @date 2021-01-22
 */
@Table(name = "ws_device_basics")
public class DeviceBasics {
    private static final long serialVersionUID = 1L;

    /**
     *
     */
    @Id
    @KeySql(useGeneratedKeys = true)
    private String deviceId;

    /**
     * 电池库存信息
     */
    @Excel(name = "电池库存信息")
    private String stock;

    /**
     * 库存更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "库存更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date stockUpdateTime;

    /**
     * 库存详情信息【ws设备】
     */
    @Excel(name = "库存详情信息【ws设备】")
    private String detailStock;

    /**
     * 库存详情时间【ws设备】
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "库存详情时间【ws设备】", width = 30, dateFormat = "yyyy-MM-dd")
    private Date detailStockTime;

    /**
     * 固件版本
     */
    @Excel(name = "固件版本")
    private String firmwareVersion;

    /**
     * 可用充电宝数(可借的)
     */
    @Excel(name = "可用充电宝数(可借的)")
    private Integer usableBattery;

    /**
     * 在库电池数
     */
    @Excel(name = "在库电池数")
    private Integer inStockTotal;

    /**
     * 更新电池数时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "更新电池数时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date updateNumTime;

    /**
     * 信号值
     */
    @Excel(name = "信号值")
    private String csq;


    private String ccid;


    // 设备电池
    private Integer allBattery;


    private String lockBatterys;


    public String getLockBatterys() {
        return lockBatterys;
    }

    public void setLockBatterys(String lockBatterys) {
        this.lockBatterys = lockBatterys;
    }

    public Integer getAllBattery() {
        return allBattery;
    }

    public void setAllBattery(Integer allBattery) {
        this.allBattery = allBattery;
    }

    public void setDeviceId(String deviceId) {
        this.deviceId = deviceId;
    }

    public String getDeviceId() {
        return deviceId;
    }

    public void setStock(String stock) {
        this.stock = stock;
    }

    public String getStock() {
        return stock;
    }

    public void setStockUpdateTime(Date stockUpdateTime) {
        this.stockUpdateTime = stockUpdateTime;
    }

    public Date getStockUpdateTime() {
        return stockUpdateTime;
    }

    public void setDetailStock(String detailStock) {
        this.detailStock = detailStock;
    }

    public String getDetailStock() {
        return detailStock;
    }

    public void setDetailStockTime(Date detailStockTime) {
        this.detailStockTime = detailStockTime;
    }

    public Date getDetailStockTime() {
        return detailStockTime;
    }

    public void setFirmwareVersion(String firmwareVersion) {
        this.firmwareVersion = firmwareVersion;
    }

    public String getFirmwareVersion() {
        return firmwareVersion;
    }

    public void setUsableBattery(Integer usableBattery) {
        this.usableBattery = usableBattery;
    }

    public Integer getUsableBattery() {
        return usableBattery;
    }

    public void setInStockTotal(Integer inStockTotal) {
        this.inStockTotal = inStockTotal;
    }

    public Integer getInStockTotal() {
        return inStockTotal;
    }

    public void setUpdateNumTime(Date updateNumTime) {
        this.updateNumTime = updateNumTime;
    }

    public Date getUpdateNumTime() {
        return updateNumTime;
    }

    public void setCsq(String csq) {
        this.csq = csq;
    }

    public String getCsq() {
        return csq;
    }


    public String getCcid() {
        return ccid;
    }

    public void setCcid(String ccid) {
        this.ccid = ccid;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("deviceId", getDeviceId())
                .append("stock", getStock())
                .append("stockUpdateTime", getStockUpdateTime())
                .append("detailStock", getDetailStock())
                .append("detailStockTime", getDetailStockTime())
                .append("firmwareVersion", getFirmwareVersion())
                .append("usableBattery", getUsableBattery())
                .append("inStockTotal", getInStockTotal())
                .append("updateNumTime", getUpdateNumTime())
                .append("csq", getCsq())
                .toString();
    }
}
